1. Field of the Invention
The present invention relates to a magnetic sensor for detecting the speed of rotation for example of a gear-shaped magnetic rotor, and also to a method of producing such a magnetic sensor.
2. Description of the Related Art
FIG. 8 is a side view of a conventional magnetic sensor and a gear-shaped magnetic rotor detected by the magnetic sensor. FIG. 9 is a cross-sectional view taken along line IX--IX of FIG. 8. In FIGS. 8 and 9, the magnetic sensor includes: a main sensor unit 1 made up of an electric insulating resin on which an electric component is mounted; and a case 2 made up of an electric insulating resin covering the main sensor unit 1 in a sealed fashion. The main sensor unit 1 includes a main part 1a, a seating 1b, an intermediate part 1c, and a connector 1d. The main part 1a includes a Hall element 3 which is the most important component of the magnetic sensor, a permanent magnet 4, and a circuit board 7 on which a circuit pattern 6 is formed and on which electronic components 5 are mounted.
The intermediate part 1c has a substantially rectangular shape with a small length wherein the seating 1b with the shape of a circular step is formed on one end of the intermediate part 1c such that the axis of the seating 1b is coincident with that of the intermediate part 1c. The end face of the intermediate part 1c is formed into a substantially rectangular shape, and the diameter of the seating 1b is less than the side length of the intermediate part 1c.
The exterior circumferential surface of the seating 1b serves as a fitting-in portion 1e fitted into the case 2 which will be described in detail later. An O-ring groove 1f is formed along the circumference of the fitting-in portion 1e, and an O-ring 9 is disposed in the O-ring groove 1f. When the components are assembled into a complete magnetic sensor, the seating 1b is fitted in an opening at an end of the case 2 so that a closed space is created in the case 2. The main part 1a is disposed on the principal surface of the seating 1b in such a manner that the main part 1a extends in a direction perpendicular to the principal surface of the seating 1b.
The main part 1a is formed into the shape of a substantially rectangular and long plate, and one end of the main part 1a is connected at a right angle to the principal surface of the seating 1b. The circuit board 7 is mounted on one principal surface of the main part 1a. The permanent magnet 4 is mounted at a right angle on the other end of the main part 1a. The Hall element 3 serving as the sensor element for detecting the magnetic material approaching the sensor element is disposed on the outer-side principal surface of the permanent magnet 4.
The connector 1d extends from the other end face of the intermediate part 1c. After extending from the other end face of the intermediate part 1c in a direction opposite to the main part 1a, the connector 1d bends into a direction perpendicular to the main part 1a. Terminals electrically connected to the circuit pattern 6 of the main part 1a are embedded in the connector 1d. A receiving cavity is formed in the L-shaped end portion of the connector 1d and the terminals 8 project into the receiving cavity so that a connector of an external device can be fitted into the receiving cavity.
The main sensor unit 1 is produced by forming the main part 1a, the seating 1b, the intermediate part 1c, and the connector 1d in an integral form including the terminals 8 embedded therein by means of molding. After that, the Hall element 3, the permanent magnet 4, and the circuit board 7 are attached.
The case 2 is produced in an integral fashion by means of molding in such a manner as to include: a sleeve 2a in the form of a cylinder with a closed end; a flange which is formed at an open end of the sleeve 2a by increasing the wall thickness of the end portion of sleeve 2a in outward radial directions; a supporting projection 2c extending outward in a radial direction from the flange 2b; and a holder 2d including three plates extending from the principal surface of the flange 2b in a direction parallel to the sleeve 2a.
The sleeve 2a produced into the form of the cylinder with the closed end has a length similar to that of the main part 1a of the main sensor unit 1, and has an inner diameter slightly greater than the width of the main part 1a. The main part 1a of the main sensor unit 1 is placed in the sleeve 2a in such a manner that the central axis of the main part 1a is coincident with that of the sleeve. The Hall element 2 disposed on the end of the main part 1a is in contact with the closed end of the sleeve 2a. The sleeve 2a has a receiving portion 2e, inside the sleeve at its open end, for receiving the seating 1b of the main sensor unit 1.
As described earlier, the O-ring 9 is disposed on the seating 1b of the main sensor unit 1. The inner diameter of the receiving portion 2e formed at the open end of the sleeve 2a is slightly greater than the diameter of the seating 1b. The seating 1b is loosely fitted into the sleeve 2a in such a manner that the open end of the sleeve 2a is closed with the seating 1b. The O-ring 9 serves to seal the connection between the seating 1b and the open end of the sleeve so that a tightly sealed space is created in the case 2. The main part 1a of the main sensor unit 1 is placed in this tightly sealed space. The O-ring 9 serves not only to seal the case 2 but also to position the main part 1a of the main sensor unit 1 at the center of the case 2.
The flange 2b is formed by increasing the wall thickness of the open end portion of the sleeve 2a outward in radial directions over the entire circumference. The supporting projection 2c extends outward in a radial direction from the flange 2b. A fixing hole 2f is formed in the end portion of the supporting projection 2c in such a manner that the fixing hole 2f extends in parallel to the axis of the sleeve 2a. The magnetic sensor is fixed to a desired location with a screw (not shown) fitted into the fixing hole 2f formed in the supporting projection 2c.
The holder 2d is composed of three plates extending from the principal surface of the flange 2b in the direction parallel to the axis of the sleeve 2a. The three plates are disposed in such a manner that the principal surface of each plate is in contact with corresponding one of three side surfaces of the intermediate part 1c of the main part 1. Because three side faces of the intermediate part 1c are in contact with the corresponding principal surfaces of the holder 2d, the main sensor unit 1 is prevented from rotating relative to the case 2. The intermediate part 1c and the holder 2d serve as a fitting-in part and receiving part, respectively, which are fitted to each other such that the main part 1a is firmly placed in the sleeve 2a without encountering relative rotation.
At the final stage of production process, the upper end portions 2g of the holder 2d are bent inward into an L shape in cross section along the entire length, by means of heat caulking. The upper end portions 2g are in contact with the corner of the end face of the intermediate part 1c of the main sensor unit 1 and thus the upper end portions 2g serve to prevent the main part 1a from moving outward from the inside of the sleeve 2a.
The magnetic sensor constructed in the above-described manner is fixed to a desired location with a screw fitted through the fixing hole 2f formed in the supporting projection 2b. When a gear-shaped magnetic rotor 20 made up of a magnetic material such as a iron disposed near the magnetic sensor is rotated, the recessed portions 20a and the protruding portions 20b alternately approach and pass by the Hall element 3. As a result, a variation occurs in the magnetic field which emerges from the permanent magnet 4 and is applied to the Hall element 3. The variation in the magnetic field is detected as a variation in voltage by the Hall element 3. The variation in voltage generated by the Hall element 3 is then converted by the electronic components 5 into a pulse signal. The electric signal in the pulse form is transmitted to an external device (not shown) via the terminals 8 of the connector 1d so as to detect the speed of rotation of the magnetic rotor 20.
In the production process of the magnetic sensor, a resin part of the main sensor unit 1 is first produced by forming the main part 1a, the seating 1b, the intermediate part 1c, and the connector 1d in an integral form including the terminals 8 embedded therein by means of molding. The Hall element 3, the permanent magnet 4, and the circuit board 7 are then mounted on the above resin part. The case 2 is also produced in an integral fashion by means of molding. Then the main sensor unit 1 is inserted into the case 2, and the upper end portions 2g of the holder 2d of the case 2 are caulked at a high temperature so that the main sensor unit 1 and the case 2 are combined together into a completely integral form.
The conventional magnetic sensor described above has the following problems. When the main sensor unit 1 and the case 2 are produced by means of molding, flash occurs at the mold juncture. In general, the mold is divided into two parts along a longitudinal direction. In the specific example of the magnetic sensor described above, the mold used in the resin molding process for the main sensor unit 1 is divided along the longitudinal axis of the main part 1a. As a result, flash can occur such that the flash extends across the O-ring groove 1f. Such flash across the O-ring groove 1f causes a leaky seal between the O-ring 9 and the O-ring groove 1f. This causes a reduction in production yield, which is a serious problem.
Furthermore, in the above conventional technique, the main sensor unit 1 is positioned with respect to the case 2 via the O-ring 9. However, because the O-ring 9 is made up of an elastic material which can change in shape, the position of the main sensor unit 1 cannot be perfectly fixed relative to the case 2. This causes a reduction in the sensor accuracy.
Thus, it is a general object of the present invention to solve the above problems. More specifically, it is an object of the present invention to provide a high-reliability magnetic sensor which can be produced with a high yield and at a low cost.